<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!-- NewPage -->
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html" charset="UTF-8">
<title>PixelsWriter (PNGJ 2.1.1-SNAPSHOT API)</title>
<link rel="stylesheet" type="text/css" href="../../../../../stylesheet.css" title="Style">
</head>
<body>
<script type="text/javascript"><!--
    if (location.href.indexOf('is-external=true') == -1) {
        parent.document.title="PixelsWriter (PNGJ 2.1.1-SNAPSHOT API)";
    }
//-->
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a name="navbar_top">
<!--   -->
</a><a href="#skip-navbar_top" title="Skip navigation links"></a><a name="navbar_top_firstrow">
<!--   -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/PixelsWriter.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../../index-all.html">Index</a></li>
<li><a href="../../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../../../ar/com/hjg/pngj/pixels/FiltersPerformance.html" title="class in ar.com.hjg.pngj.pixels"><span class="strong">Prev Class</span></a></li>
<li><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriterDefault.html" title="class in ar.com.hjg.pngj.pixels"><span class="strong">Next Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../../../index.html?ar/com/hjg/pngj/pixels/PixelsWriter.html" target="_top">Frames</a></li>
<li><a href="PixelsWriter.html" target="_top">No Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_top">
<li><a href="../../../../../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
  allClassesLink = document.getElementById("allclasses_navbar_top");
  if(window==top) {
    allClassesLink.style.display = "block";
  }
  else {
    allClassesLink.style.display = "none";
  }
  //-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li><a href="#field_summary">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor_summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li><a href="#field_detail">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor_detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_detail">Method</a></li>
</ul>
</div>
<a name="skip-navbar_top">
<!--   -->
</a></div>
<!-- ========= END OF TOP NAVBAR ========= -->
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<div class="subTitle">ar.com.hjg.pngj.pixels</div>
<h2 title="Class PixelsWriter" class="title">Class PixelsWriter</h2>
</div>
<div class="contentContainer">
<ul class="inheritance">
<li><a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</a></li>
<li>
<ul class="inheritance">
<li>ar.com.hjg.pngj.pixels.PixelsWriter</li>
</ul>
</li>
</ul>
<div class="description">
<ul class="blockList">
<li class="blockList">
<dl>
<dt>Direct Known Subclasses:</dt>
<dd><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriterDefault.html" title="class in ar.com.hjg.pngj.pixels">PixelsWriterDefault</a>, <a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriterMultiple.html" title="class in ar.com.hjg.pngj.pixels">PixelsWriterMultiple</a></dd>
</dl>
<hr>
<br>
<pre>public abstract class <span class="strong">PixelsWriter</span>
extends <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></pre>
<div class="block">Encodes a set of rows (pixels) as a continuous deflated stream (does not know about IDAT chunk segmentation).
 <p>
 This includes the filter selection strategy, plus the filtering itself and the deflating. Only supports fixed length
 rows (no interlaced writing).
 <p>
 Typically an instance of this is hold by a PngWriter - but more instances could be used (for APGN)</div>
</li>
</ul>
</div>
<div class="summary">
<ul class="blockList">
<li class="blockList">
<!-- =========== FIELD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="field_summary">
<!--   -->
</a>
<h3>Field Summary</h3>
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Field Summary table, listing fields, and an explanation">
<caption><span>Fields</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Field and Description</th>
</tr>
<tr class="altColor">
<td class="colFirst"><code>protected int</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#buflen">buflen</a></strong></code>
<div class="block">row buffer length, including filter byte (imgInfo.bytesPerRow + 1)</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>protected int</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#bytesPixel">bytesPixel</a></strong></code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>protected int</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#bytesRow">bytesRow</a></strong></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>protected int</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#currentRow">currentRow</a></strong></code>
<div class="block">row being processed, couting from zero</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>protected int</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#deflaterCompLevel">deflaterCompLevel</a></strong></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>protected int</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#deflaterStrategy">deflaterStrategy</a></strong></code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>protected <a href="../../../../../ar/com/hjg/pngj/FilterType.html" title="enum in ar.com.hjg.pngj">FilterType</a></code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#filterType">filterType</a></strong></code>
<div class="block">This is the globally configured filter type - it can be a concrete type or a pseudo type (hint or strategy)</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>protected <a href="../../../../../ar/com/hjg/pngj/ImageInfo.html" title="class in ar.com.hjg.pngj">ImageInfo</a></code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#imgInfo">imgInfo</a></strong></code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>protected boolean</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#initdone">initdone</a></strong></code>&nbsp;</td>
</tr>
</table>
</li>
</ul>
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor_summary">
<!--   -->
</a>
<h3>Constructor Summary</h3>
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation">
<caption><span>Constructors</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colOne" scope="col">Constructor and Description</th>
</tr>
<tr class="altColor">
<td class="colOne"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#PixelsWriter(ar.com.hjg.pngj.ImageInfo)">PixelsWriter</a></strong>(<a href="../../../../../ar/com/hjg/pngj/ImageInfo.html" title="class in ar.com.hjg.pngj">ImageInfo</a>&nbsp;imgInfo)</code>&nbsp;</td>
</tr>
</table>
</li>
</ul>
<!-- ========== METHOD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="method_summary">
<!--   -->
</a>
<h3>Method Summary</h3>
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
<caption><span>Methods</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Method and Description</th>
</tr>
<tr class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#close()">close</a></strong>()</code>
<div class="block">cleanup.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>protected abstract void</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#filterAndWrite(byte[])">filterAndWrite</a></strong>(byte[]&nbsp;rowb)</code>
<div class="block">This does the filtering and send to stream.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>protected byte[]</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#filterRowWithFilterType(ar.com.hjg.pngj.FilterType, byte[], byte[], byte[])">filterRowWithFilterType</a></strong>(<a href="../../../../../ar/com/hjg/pngj/FilterType.html" title="enum in ar.com.hjg.pngj">FilterType</a>&nbsp;_filterType,
                       byte[]&nbsp;_rowb,
                       byte[]&nbsp;_rowbprev,
                       byte[]&nbsp;_rowf)</code>
<div class="block">Does the real filtering.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>double</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#getCompression()">getCompression</a></strong>()</code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>protected <a href="../../../../../ar/com/hjg/pngj/FilterType.html" title="enum in ar.com.hjg.pngj">FilterType</a></code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#getDefaultFilter()">getDefaultFilter</a></strong>()</code>
<div class="block">computed default fixed filter type to use, if specified DEFAULT; wilde guess based on image properties</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code><a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Integer.html?is-external=true" title="class or interface in java.lang">Integer</a></code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#getDeflaterCompLevel()">getDeflaterCompLevel</a></strong>()</code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code><a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#getFiltersUsed()">getFiltersUsed</a></strong>()</code>
<div class="block">informational stats : filter used, in percentages</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code><a href="../../../../../ar/com/hjg/pngj/FilterType.html" title="enum in ar.com.hjg.pngj">FilterType</a></code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#getFilterType()">getFilterType</a></strong>()</code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code><a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a></code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#getOs()">getOs</a></strong>()</code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>abstract byte[]</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#getRowb()">getRowb</a></strong>()</code>
<div class="block">This will be called by the PngWrite to fill the raw pixels for each row.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>long</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#getTotalBytesToWrite()">getTotalBytesToWrite</a></strong>()</code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#init()">init</a></strong>()</code>
<div class="block">This will be called lazily just before writing row 0.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#initParams()">initParams</a></strong>()</code>
<div class="block">called by init(); override (calling this first) to do additional initialization</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#isDone()">isDone</a></strong>()</code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#processRow(byte[])">processRow</a></strong>(byte[]&nbsp;rowb)</code>
<div class="block">main internal point for external call.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#sendToCompressedStream(byte[])">sendToCompressedStream</a></strong>(byte[]&nbsp;rowf)</code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#setCompressorStream(ar.com.hjg.pngj.pixels.CompressorStream)">setCompressorStream</a></strong>(<a href="../../../../../ar/com/hjg/pngj/pixels/CompressorStream.html" title="class in ar.com.hjg.pngj.pixels">CompressorStream</a>&nbsp;compressorStream)</code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#setDeflaterCompLevel(java.lang.Integer)">setDeflaterCompLevel</a></strong>(<a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Integer.html?is-external=true" title="class or interface in java.lang">Integer</a>&nbsp;deflaterCompLevel)</code>
<div class="block">Deflater (ZLIB) compression level, between 0 (no compression) and 9</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#setDeflaterStrategy(java.lang.Integer)">setDeflaterStrategy</a></strong>(<a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Integer.html?is-external=true" title="class or interface in java.lang">Integer</a>&nbsp;deflaterStrategy)</code>
<div class="block">Deflater (ZLIB) strategy.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#setFilterType(ar.com.hjg.pngj.FilterType)">setFilterType</a></strong>(<a href="../../../../../ar/com/hjg/pngj/FilterType.html" title="enum in ar.com.hjg.pngj">FilterType</a>&nbsp;filterType)</code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#setIdatMaxSize(int)">setIdatMaxSize</a></strong>(int&nbsp;idatMaxSize)</code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#setOs(java.io.OutputStream)">setOs</a></strong>(<a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a>&nbsp;datStream)</code>&nbsp;</td>
</tr>
</table>
<ul class="blockList">
<li class="blockList"><a name="methods_inherited_from_class_java.lang.Object">
<!--   -->
</a>
<h3>Methods inherited from class&nbsp;java.lang.<a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></h3>
<code><a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#clone()" title="class or interface in java.lang">clone</a>, <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang">equals</a>, <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#finalize()" title="class or interface in java.lang">finalize</a>, <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang">getClass</a>, <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang">hashCode</a>, <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#notify()" title="class or interface in java.lang">notify</a>, <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#notifyAll()" title="class or interface in java.lang">notifyAll</a>, <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#toString()" title="class or interface in java.lang">toString</a>, <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait()" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long)" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</a></code></li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
<div class="details">
<ul class="blockList">
<li class="blockList">
<!-- ============ FIELD DETAIL =========== -->
<ul class="blockList">
<li class="blockList"><a name="field_detail">
<!--   -->
</a>
<h3>Field Detail</h3>
<a name="imgInfo">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>imgInfo</h4>
<pre>protected final&nbsp;<a href="../../../../../ar/com/hjg/pngj/ImageInfo.html" title="class in ar.com.hjg.pngj">ImageInfo</a> imgInfo</pre>
</li>
</ul>
<a name="buflen">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>buflen</h4>
<pre>protected final&nbsp;int buflen</pre>
<div class="block">row buffer length, including filter byte (imgInfo.bytesPerRow + 1)</div>
</li>
</ul>
<a name="bytesPixel">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>bytesPixel</h4>
<pre>protected final&nbsp;int bytesPixel</pre>
</li>
</ul>
<a name="bytesRow">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>bytesRow</h4>
<pre>protected final&nbsp;int bytesRow</pre>
</li>
</ul>
<a name="deflaterCompLevel">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>deflaterCompLevel</h4>
<pre>protected&nbsp;int deflaterCompLevel</pre>
</li>
</ul>
<a name="deflaterStrategy">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>deflaterStrategy</h4>
<pre>protected&nbsp;int deflaterStrategy</pre>
</li>
</ul>
<a name="initdone">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>initdone</h4>
<pre>protected&nbsp;boolean initdone</pre>
</li>
</ul>
<a name="filterType">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>filterType</h4>
<pre>protected&nbsp;<a href="../../../../../ar/com/hjg/pngj/FilterType.html" title="enum in ar.com.hjg.pngj">FilterType</a> filterType</pre>
<div class="block">This is the globally configured filter type - it can be a concrete type or a pseudo type (hint or strategy)</div>
</li>
</ul>
<a name="currentRow">
<!--   -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>currentRow</h4>
<pre>protected&nbsp;int currentRow</pre>
<div class="block">row being processed, couting from zero</div>
</li>
</ul>
</li>
</ul>
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor_detail">
<!--   -->
</a>
<h3>Constructor Detail</h3>
<a name="PixelsWriter(ar.com.hjg.pngj.ImageInfo)">
<!--   -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>PixelsWriter</h4>
<pre>public&nbsp;PixelsWriter(<a href="../../../../../ar/com/hjg/pngj/ImageInfo.html" title="class in ar.com.hjg.pngj">ImageInfo</a>&nbsp;imgInfo)</pre>
</li>
</ul>
</li>
</ul>
<!-- ============ METHOD DETAIL ========== -->
<ul class="blockList">
<li class="blockList"><a name="method_detail">
<!--   -->
</a>
<h3>Method Detail</h3>
<a name="processRow(byte[])">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>processRow</h4>
<pre>public final&nbsp;void&nbsp;processRow(byte[]&nbsp;rowb)</pre>
<div class="block">main internal point for external call. It does the lazy initializion if necessary, sets current row, and call
 <a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#filterAndWrite(byte[])"><code>filterAndWrite(byte[])</code></a></div>
</li>
</ul>
<a name="sendToCompressedStream(byte[])">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>sendToCompressedStream</h4>
<pre>protected&nbsp;void&nbsp;sendToCompressedStream(byte[]&nbsp;rowf)</pre>
</li>
</ul>
<a name="filterAndWrite(byte[])">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>filterAndWrite</h4>
<pre>protected abstract&nbsp;void&nbsp;filterAndWrite(byte[]&nbsp;rowb)</pre>
<div class="block">This does the filtering and send to stream. Typically should decide the filtering, call
 <a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#filterRowWithFilterType(ar.com.hjg.pngj.FilterType, byte[], byte[], byte[])"><code>filterRowWithFilterType(FilterType, byte[], byte[], byte[])</code></a> and and
 <a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#sendToCompressedStream(byte[])"><code>sendToCompressedStream(byte[])</code></a></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>rowb</code> - </dd></dl>
</li>
</ul>
<a name="filterRowWithFilterType(ar.com.hjg.pngj.FilterType, byte[], byte[], byte[])">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>filterRowWithFilterType</h4>
<pre>protected final&nbsp;byte[]&nbsp;filterRowWithFilterType(<a href="../../../../../ar/com/hjg/pngj/FilterType.html" title="enum in ar.com.hjg.pngj">FilterType</a>&nbsp;_filterType,
                             byte[]&nbsp;_rowb,
                             byte[]&nbsp;_rowbprev,
                             byte[]&nbsp;_rowf)</pre>
<div class="block">Does the real filtering. This must be called with the real (standard) filterType. This should rarely be overriden.
 <p>
 WARNING: look out the contract</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>_filterType</code> - </dd><dd><code>_rowb</code> - current row (the first byte might be modified)</dd><dd><code>_rowbprev</code> - previous row (should be all zero the first time)</dd><dd><code>_rowf</code> - tentative buffer to store the filtered bytes. might not be used!</dd>
<dt><span class="strong">Returns:</span></dt><dd>normally _rowf, but eventually _rowb. This MUST NOT BE MODIFIED nor reused by caller</dd></dl>
</li>
</ul>
<a name="getRowb()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getRowb</h4>
<pre>public abstract&nbsp;byte[]&nbsp;getRowb()</pre>
<div class="block">This will be called by the PngWrite to fill the raw pixels for each row. This can change from call to call.
 Warning: this can be called before the object is init, implementations should call init() to be sure</div>
</li>
</ul>
<a name="init()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>init</h4>
<pre>protected final&nbsp;void&nbsp;init()</pre>
<div class="block">This will be called lazily just before writing row 0. Idempotent.</div>
</li>
</ul>
<a name="initParams()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>initParams</h4>
<pre>protected&nbsp;void&nbsp;initParams()</pre>
<div class="block">called by init(); override (calling this first) to do additional initialization</div>
</li>
</ul>
<a name="close()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>close</h4>
<pre>public&nbsp;void&nbsp;close()</pre>
<div class="block">cleanup. This should be called explicitly. Idempotent and secure</div>
</li>
</ul>
<a name="setDeflaterStrategy(java.lang.Integer)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setDeflaterStrategy</h4>
<pre>public&nbsp;void&nbsp;setDeflaterStrategy(<a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Integer.html?is-external=true" title="class or interface in java.lang">Integer</a>&nbsp;deflaterStrategy)</pre>
<div class="block">Deflater (ZLIB) strategy. You should rarely change this from the default (Deflater.DEFAULT_STRATEGY) to
 Deflater.FILTERED (Deflater.HUFFMAN_ONLY is fast but compress poorly)</div>
</li>
</ul>
<a name="setDeflaterCompLevel(java.lang.Integer)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setDeflaterCompLevel</h4>
<pre>public&nbsp;void&nbsp;setDeflaterCompLevel(<a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Integer.html?is-external=true" title="class or interface in java.lang">Integer</a>&nbsp;deflaterCompLevel)</pre>
<div class="block">Deflater (ZLIB) compression level, between 0 (no compression) and 9</div>
</li>
</ul>
<a name="getDeflaterCompLevel()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getDeflaterCompLevel</h4>
<pre>public&nbsp;<a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Integer.html?is-external=true" title="class or interface in java.lang">Integer</a>&nbsp;getDeflaterCompLevel()</pre>
</li>
</ul>
<a name="setOs(java.io.OutputStream)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setOs</h4>
<pre>public final&nbsp;void&nbsp;setOs(<a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a>&nbsp;datStream)</pre>
</li>
</ul>
<a name="getOs()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getOs</h4>
<pre>public&nbsp;<a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a>&nbsp;getOs()</pre>
</li>
</ul>
<a name="getFilterType()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getFilterType</h4>
<pre>public final&nbsp;<a href="../../../../../ar/com/hjg/pngj/FilterType.html" title="enum in ar.com.hjg.pngj">FilterType</a>&nbsp;getFilterType()</pre>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#filterType"><code>filterType</code></a></dd></dl>
</li>
</ul>
<a name="setFilterType(ar.com.hjg.pngj.FilterType)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setFilterType</h4>
<pre>public final&nbsp;void&nbsp;setFilterType(<a href="../../../../../ar/com/hjg/pngj/FilterType.html" title="enum in ar.com.hjg.pngj">FilterType</a>&nbsp;filterType)</pre>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriter.html#filterType"><code>filterType</code></a></dd></dl>
</li>
</ul>
<a name="getCompression()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getCompression</h4>
<pre>public&nbsp;double&nbsp;getCompression()</pre>
</li>
</ul>
<a name="setCompressorStream(ar.com.hjg.pngj.pixels.CompressorStream)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setCompressorStream</h4>
<pre>public&nbsp;void&nbsp;setCompressorStream(<a href="../../../../../ar/com/hjg/pngj/pixels/CompressorStream.html" title="class in ar.com.hjg.pngj.pixels">CompressorStream</a>&nbsp;compressorStream)</pre>
</li>
</ul>
<a name="getTotalBytesToWrite()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getTotalBytesToWrite</h4>
<pre>public&nbsp;long&nbsp;getTotalBytesToWrite()</pre>
</li>
</ul>
<a name="isDone()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isDone</h4>
<pre>public&nbsp;boolean&nbsp;isDone()</pre>
</li>
</ul>
<a name="getDefaultFilter()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getDefaultFilter</h4>
<pre>protected&nbsp;<a href="../../../../../ar/com/hjg/pngj/FilterType.html" title="enum in ar.com.hjg.pngj">FilterType</a>&nbsp;getDefaultFilter()</pre>
<div class="block">computed default fixed filter type to use, if specified DEFAULT; wilde guess based on image properties</div>
<dl><dt><span class="strong">Returns:</span></dt><dd>One of the five concrete filter types</dd></dl>
</li>
</ul>
<a name="getFiltersUsed()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getFiltersUsed</h4>
<pre>public final&nbsp;<a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;getFiltersUsed()</pre>
<div class="block">informational stats : filter used, in percentages</div>
</li>
</ul>
<a name="setIdatMaxSize(int)">
<!--   -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>setIdatMaxSize</h4>
<pre>public&nbsp;void&nbsp;setIdatMaxSize(int&nbsp;idatMaxSize)</pre>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
</div>
<!-- ========= END OF CLASS DATA ========= -->
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a name="navbar_bottom">
<!--   -->
</a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow">
<!--   -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/PixelsWriter.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../../index-all.html">Index</a></li>
<li><a href="../../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../../../ar/com/hjg/pngj/pixels/FiltersPerformance.html" title="class in ar.com.hjg.pngj.pixels"><span class="strong">Prev Class</span></a></li>
<li><a href="../../../../../ar/com/hjg/pngj/pixels/PixelsWriterDefault.html" title="class in ar.com.hjg.pngj.pixels"><span class="strong">Next Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../../../index.html?ar/com/hjg/pngj/pixels/PixelsWriter.html" target="_top">Frames</a></li>
<li><a href="PixelsWriter.html" target="_top">No Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_bottom">
<li><a href="../../../../../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
  allClassesLink = document.getElementById("allclasses_navbar_bottom");
  if(window==top) {
    allClassesLink.style.display = "block";
  }
  else {
    allClassesLink.style.display = "none";
  }
  //-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li><a href="#field_summary">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor_summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li><a href="#field_detail">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor_detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_detail">Method</a></li>
</ul>
</div>
<a name="skip-navbar_bottom">
<!--   -->
</a></div>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<p class="legalCopy"><small>Copyright &#169; 2014. All rights reserved.</small></p>
</body>
</html>
